package com.qidian.buy.goods.mapper;

import com.qidian.buy.goods.entity.Item;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 商品表 Mapper 接口
 * </p>
 *
 * @author 戴着假发的程序员
 * @since 2024-05-08
 */
public interface ItemMapper extends BaseMapper<Item> {
    Item getByItemId(Long itemId);
    int deleteItemAndSpeRelationByItemId(Long itemId);
    int addItemAndSpeRelation(@Param("itemId") Long itemId, @Param("speIds") List<Long> speId);

    List<Long> getSpeIdByItemId(Long itemId);
}
